import { IsNotEmpty, IsOptional, IsString } from 'class-validator';
import { ApiProperty } from '@nestjs/swagger';
export class SignUpDto {
  @IsString()
  @IsNotEmpty()
  @ApiProperty({ description: '用户名称' })
  name: string;

  @IsString()
  @IsNotEmpty()
  @ApiProperty({ description: '用户密码' })
  password: string;

  @IsString()
  @IsOptional()
  nickname: string;

  @IsString()
  @IsNotEmpty()
  @ApiProperty({ description: '省份' })
  province: string;

  @IsString()
  @IsNotEmpty()
  @ApiProperty({ description: '城市' })
  city: string;

  @IsString()
  @IsNotEmpty()
  @ApiProperty({ description: '电话' })
  phone: string;

  @IsString()
  @IsNotEmpty()
  @ApiProperty({ description: '角色权限' })
  role: string;
}
